<?php
if (!defined('IN_XLP')) {
    exit('Access Denied');
}
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta id="viewport" name="viewport" content="width=device-width; initial-scale=1.0; maximum-scale=1.0; user-scalable=0;"/>
<title>小区通知</title>
<?php 
getCss(array('mp/mp_msg'));
getJs(array('global/jquery-1.7.1.min'));
?>
<style>
body{margin-bottom:48px}
a{text-decoration:none; color:#666}
.msg_title_bar .msg_title{color:#FFF}
#load-more,#no-data{margin:20px auto; height:30px; line-height:30px; text-align:center; font-size:14px; background:#FFF}
#loading-data{ width:130px;background:url(<?php echo IMG_PATH?>mp/loading151fd8.gif) 0 center no-repeat; height:40px; line-height:40px; margin:20px auto; padding-left:20px; display:none}
#no-data{color:#666666; display:none}
#no-news{ width:300px; height:100px; line-height:80px; font-size:20px; text-align:center; margin:20px auto;}
</style>
</head>

<body>
<div class="msg_page">
<?php
echo '<div id="show-housedata">';
	foreach($rs as $val){
		if ($val['isOk']){
		if ($val['type']=='one'){
?>
  <div class="msg_list">
    <div class="msg_list_hd"><h3 class="msg_list_date"><?php echo outTime($val['header']['infotime'],2);?></h3></div>
    <div class="msg_list_bd">
      <div id="wxsmg" class="msg_wrapper">
        <p class="msg_date"><?php echo outTime($val['header']['infotime'],2);?></p>
        <div class="msg_inner_wrapper default_box news_box">
        <a href="<?php echo $val['header']['url'];?>">
          <div class="msg_item news">
            <div class="msg_item_hd"><h4 class="msg_title"><?php echo $val['header']['title'];?></h4></div>
            <div class="msg_item_bd">
            <?php
            if ($val['header']['picurl']){
			?>
              <div class="msg_cover"><img src="<?php echo getImgUrl($val['header']['picurl']);?>" style="width:300px; height:200px"/></div>
            <?php
			}
			?>
              <p class="msg_desc">
				<?php echo $val['header']['description'];?>
              </p>
            </div>
            <div class="msg_item_ft">阅读原文<span class="add_on_icon arrow"></span></div>
          </div>
          </a>
        </div>
      </div>
    </div>
  </div>
<?php
	}else{
?>
  <div class="msg_list">
    <div class="msg_list_hd"><h3 class="msg_list_date"><?php echo outTime($val['header']['infotime'],2);?></h3></div>
    
    <div class="msg_list_bd">
      <div id="wxsmg" class="msg_wrapper">
        <p class="msg_date"><?php echo outTime($val['header']['infotime'],2);?></p>
        <div class="msg_inner_wrapper default_box news_box">
          <div class="msg_item multi_news">
          <a href="<?php echo $val['header']['url'];?>">
            <div class="msg_cover">
              <img src="<?php echo getImgUrl($val['header']['picurl']);?>" style="width:300px; height:200px"/>
              <div class="msg_title_bar"><h4 class="msg_title"><?php echo $val['header']['title'];?></h4></div>
            </div>
           </a> 
            <?php
				foreach($val['items'] as $value){
			?>
            <div class="sub_msg_list">
            <a href="<?php echo $value['url'];?>">
              <div class="sub_msg_item">
                <span class="thumb"><img src="<?php echo getImgUrl($value['picurl']);?>" style="width:80px; height:80px"/></span>
                <h4 class="msg_title"><?php echo $value['title'];?></h4>
              </div>
              </a>
            </div>
            <?php
			}
			?>
          </div>
        </div>
      </div>
    </div>
  </div>

<?php
	}
	}else{echo '文章素材已被删除';}
	}
?>
</div>

</div>
</body>
</html>